<?php

namespace app\common\model;

use think\Model;

class DeliveryKeyUserRelation extends Model
{
    //

    public function user() {
        return $this->belongsTo(User::class);
    }

    public function userShow() {
        return $this->belongsTo(User::class)->bind(['username'=>'username','nickname'=>'nickname','avatar'=>'avatar']);
    }

    public function deliveryKey() {
        return $this->belongsTo(DeliveryKey::class);
    }
}
